Skip to content

perf(supervisor-network): cache proposal coverage by policy snapshot - #3201

Merged
johntmyers merged 1 commit into
NVIDIA:mainfrom
shiju-nv:perf/3092-policy-wait-snapshot-coverage
Sep 5, 2026
Merged

perf(supervisor-network): cache proposal coverage by policy snapshot#3201
johntmyers merged 1 commit into
NVIDIA:mainfrom
shiju-nv:perf/3092-policy-wait-snapshot-coverage

Conversation

@shiju-nv

@shiju-nv shiju-nv commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Summary

Evaluate a proposed rule against each observed installed policy snapshot once instead of repeating the full coverage scan on every 200 ms timer tick. A newly installed snapshot, including a byte-identical replacement, still receives one fresh evaluation.

Related Issue

Part of #3092

Changes

  • Store the current policy as an immutable Arc snapshot so waiters can identify installations without cloning the complete policy.
  • Run coverage outside the policy lock and skip repeated evaluations while the observed snapshot remains unchanged.
  • Preserve the existing deadline and polling behavior, and add paused-time tests for unchanged, identical replacement, and covering replacement snapshots.

Testing

  • mise run pre-commit passes
  • Unit tests added/updated
  • E2E tests added/updated (if applicable)

Checklist

  • Follows Conventional Commits
  • Commits are signed off (DCO)
  • Architecture docs updated (if applicable)

Evaluate proposal coverage once per observed installed policy snapshot while preserving replacement and deadline behavior.

Signed-off-by: Shiju <shiju@nvidia.com>
@johntmyers johntmyers added the test:e2e Requires end-to-end coverage label Sep 5, 2026
@github-actions

github-actions Bot commented Sep 5, 2026

Copy link
Copy Markdown

Label test:e2e applied for 0e942e1. Open the existing run and click Re-run all jobs to execute with the label set. The run will execute the standard E2E suite after building the required gateway and supervisor images once. The matching required CI gate status on this PR will flip green automatically once the run finishes.

@johntmyers

Copy link
Copy Markdown
Collaborator

gator-agent

PR Review Status

This focused change implements issue #3092's policy-advisor snapshot evaluation requirement. The initial code review found no blocking defects; the internal performance change does not alter a direct user-facing contract, so Fern documentation is not needed. E2E dispatch is now being prepared for the supervisor network-policy path.

Blocking findings:

  • No blocking findings remain

Carried findings:

  • None

Non-blocking suggestions:

  • None
Gator metadata
  • Validation: Focused supervisor-network work with clear motivation and a direct acceptance-criterion link to issue Validate and normalize SandboxPolicy before supervisor activation #3092
  • Docs: Not needed because this is an internal evaluation-frequency optimization with preserved endpoint behavior
  • Checks: Current-head branch checks and DCO are green; required-gate refresh is running after label application
  • E2E: test:e2e applied; E2E Label Help is currently running and required E2E jobs are not yet confirmed queued
  • Head SHA: 0e942e14e20b0f891412e0d2c696af5755ac6373
  • Base SHA: 592df3e01489b3fd2af5573e1feb043108596aed
  • Merge base SHA: 592df3e01489b3fd2af5573e1feb043108596aed
  • Patch ID: d14b8b1b6f5b5fb5f2cd0e9680b5201c180068a8
  • Gator payload: 8
  • Review mode: initial
  • Previous reviewed SHA: none
  • Review budget exhausted: no
  • Maintainer decision required: no
  • Next state: gator:in-review

@johntmyers johntmyers added gator:in-review Gator is reviewing or awaiting PR review feedback gator:watch-pipeline Gator is monitoring PR CI/CD status gator:approval-needed Gator completed review; maintainer approval needed and removed gator:in-review Gator is reviewing or awaiting PR review feedback gator:watch-pipeline Gator is monitoring PR CI/CD status labels Sep 5, 2026
@johntmyers
johntmyers added this pull request to the merge queue Sep 5, 2026
@johntmyers johntmyers added gator:merge-ready and removed gator:approval-needed Gator completed review; maintainer approval needed labels Sep 5, 2026
Merged via the queue into NVIDIA:main with commit 320d4ef Sep 5, 2026
116 of 119 checks passed
@johntmyers

Copy link
Copy Markdown
Collaborator

gator-agent

Monitoring Complete

Monitoring is complete because this PR has merged.

Final status: Gator reached gator:merge-ready; the PR was approved and merged at head 0e942e14e20b0f891412e0d2c696af5755ac6373.

I removed the active gator:* label because there is nothing left for gator to monitor on this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test:e2e Requires end-to-end coverage

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants